package com.zofund.jobdispatcher.dao.middleware;

import java.util.List;
import javax.validation.constraints.NotNull;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import com.zofund.jobdispatcher.model.middleware.JobBox;

public interface JobBoxDao extends JpaRepository<JobBox,Long>{

	public List<JobBox> findAllByOrderByEventTimeAsc();

	public List<JobBox> findByJobCodeAndEventTimeBetween(String jobCode, String startDate, String endDate,Pageable pageable);

	public JobBox findOneByJobCodeAndEventTime(String jobCode, @NotNull String eventTime);

	public List<JobBox> findByEventTimeBetween(String startDate, String endDate,Pageable pageable);
	
}
